home *** CD-ROM | disk | FTP | other *** search
/ Champak 125 / Vol 125 (Damaged).iso / games / orbox.swf / scripts / DefineSprite_91 / frame_3 / DoAction.as
Encoding:
Text File  |  2008-11-13  |  691 b   |  31 lines

  1. if(_root.m != 0)
  2. {
  3.    if(this.hitTest(Math.floor((_root.pra._x + 10) / 20) * 20,Math.floor(_root.pra._y / 20) * 20 + 10,1) == false)
  4.    {
  5.       i += 1;
  6.       bb = 4;
  7.       _root.sc += 10;
  8.       this.attachMovie("sled","sled" + i,i);
  9.       this["sled" + i]._x = - _parent._x - _X + Math.floor((_root.pra._x + 10) / 20) * 20;
  10.       this["sled" + i]._y = - _parent._y - _Y + Math.floor(_root.pra._y / 20) * 20 + 10;
  11.    }
  12.    else
  13.    {
  14.       if(bb < 1)
  15.       {
  16.          _root.sc--;
  17.       }
  18.       bb--;
  19.    }
  20. }
  21. if(_root.miss == 1 or _root.cmp == 1)
  22. {
  23.    _root.miss = 0;
  24.    i1 = 1;
  25.    while(i1 < i + 1)
  26.    {
  27.       removeMovieClip(this["sled" + i1]);
  28.       i1++;
  29.    }
  30. }
  31.